{% extends "layout.html" %}
{% block content %}
    <div class="card-header clearfix">
        <div class="container">
            <div>
                <a class="btn btn-outline-primary btn-sm" style="float: left" href="/admin/add/"
                   role="button">添加管理员</a>
            </div>
            <div class="float-right">
                <form class="form-inline" method="get">
                    <input class="form-control" type="search" name="q">
                    <button class="btn btn-outline-success" type="submit">
                        <svg t="1730990414002" class="icon" viewBox="0 0 1024 1024" version="1.1"
                             xmlns="http://www.w3.org/2000/svg" p-id="3202" width="20" height="20">
                            <path d="M685.6 660.336l155.152 155.168a16 16 0 0 1 0 22.624l-11.312 11.328a16 16 0 0 1-22.624 0l-158.528-158.544a289.792 289.792 0 0 1-165.152 51.36C322.336 742.256 192 611.904 192 451.12 192 290.336 322.336 160 483.136 160c160.784 0 291.12 130.336 291.12 291.136 0 82.112-33.984 156.272-88.672 209.2z m-202.464 33.92c134.272 0 243.12-108.848 243.12-243.12C726.256 316.848 617.408 208 483.136 208 348.848 208 240 316.848 240 451.136c0 134.272 108.848 243.12 243.136 243.12z"
                                  fill="#000000" p-id="3203"></path>
                        </svg>
                    </button>
                </form>
            </div>
        </div>
    </div>

    <div class="container">
        <table class="table table-hover container ">
            <thead>
            <tr>
                <th scope="col">ID</th>
                <th scope="col">用户名</th>
                <th scope="col">密码</th>

            </tr>
            </thead>
            <tbody>
            {% for item in data %}
                <tr>
                    <th>{{ item.id }}</th>
                    <td>{{ item.username }}</td>
                    <td>*******</td>
                    <td>
                        <a class="btn btn-primary btn-sm" href="/admin/{{ item.id }}/edit" role="button">修改</a>
                        <a class="btn btn-danger btn-sm" href="/admin/{{ item.id }}/delete" role="button">删除</a>
                    </td>
                </tr>
            {% endfor %}
            </tbody>
        </table>
    </div>
    <div class="container">
        {{ page_list }}
    </div>
{% endblock %}